from flask import make_response
from functools import wraps


def set_response_no_cache(func):
    @wraps(func)
    def wrapper(*arg, **kwargs):
        temp = func(*arg, **kwargs)
        resp = make_response(temp)
        resp.headers['Cache-Control'] = 'no-cache'
        resp.headers['Cache-Control'] = 'no-store'
        return resp
    return wrapper
